package nkr1pt.popkorn.extract;

import com.google.inject.Inject;
import com.google.inject.Provider;
import nkr1pt.popkorn.events.EventBus;
import nkr1pt.popkorn.events.PopkornEventFactory;
import nkr1pt.popkorn.extract.ExtractCommandsMap;
import nkr1pt.popkorn.extract.ExtractCommandsMap;
import nkr1pt.popkorn.extract.ExtractCommandsMap;
import nkr1pt.popkorn.extract.Extractor;
import nkr1pt.popkorn.extract.Extractor;
import nkr1pt.popkorn.extract.Extractor;

/**
 *
 * @author Kristof Vanhaeren
 */
public class ExtractorProvider implements Provider<Extractor> {

    private EventBus eventBus;
    private PopkornEventFactory eventFactory;
    private ExtractCommandsMap extractCommandsMap;

    @Inject
    public ExtractorProvider(EventBus eventBus, PopkornEventFactory eventFactory, ExtractCommandsMap extractCommandsMap) {
        this.eventBus = eventBus;
        this.eventFactory = eventFactory;
        this.extractCommandsMap = extractCommandsMap;
    }

    public Extractor get() {
        Extractor extractor = new Extractor(eventBus, eventFactory, extractCommandsMap);
        return extractor;
    }

}